def hello():  # 理解为一个可迭代对象
    print("step1")
    yield 1
    print("step2")
    yield 2
    print("step3")
    yield 3


g = hello()

for res in g:
    print(res)